home *** CD-ROM | disk | FTP | other *** search
/ FishMarket 1.0 / FishMarket v1.0.iso / fishies / 351-375 / disk_352 / treewalk / readme < prev    next >
Text File  |  1992-05-06  |  3KB  |  60 lines

  1. Files contained herein:
  2.  
  3.     README            - This file
  4.     COPYING            - copying permissions for the treewalk
  5.     main.c            - main routines for treewalk program
  6.     filter.c        - code to compile & execute filter expressions
  7.     magic.c            - code to handle `strings`
  8.     errors.h        - error numbers set by parts of treewalk program
  9.     treewalk.c        - code for the treewalk function proper
  10.     treewalk.h        - header needed to use the treewalk function
  11.     Makefile        - used to build the entire mess
  12.     treewalk        - the executable
  13.     timings            - comparisons between treewalk & similar tools
  14.     treewalk.doc        - documentation on the treewalk program
  15.     treewalk.fun        - documentation on the treewalk function
  16.     daily.rexx        - simple backup script using treewalk
  17.     daily.ftw        - support routine for same
  18.     files.rexx        - emulation of the lattice files command
  19.     patname.ftw        - support routine for the above
  20.     copy.ftw        - ditto
  21.     basename.ftw        - ditto, but usefull elsewhere
  22.     rootname.ftw        - ditto, but usefull elsewhere
  23.     printcomment.ftw    - prints the comment on each file that has one
  24.     mginsert.ftw        - inserts file names into a running mg3a
  25.     nonrecursive.ftw    - can be used to limit recursion
  26.     twpath.ftw        - used by above, among others
  27.  
  28.  
  29. For hackers:
  30.  
  31. This code is written in Lattice C, uses it's ANSI features pretty
  32. heavily, and also makes heavy use of the Lattice library. You may be
  33. able to make it work with Manx, but it probably won't be easy. If you
  34. want to try, I'd recommend having the ARP library around.
  35.  
  36. The makefile is written to use my utilities, most notably make, cc &
  37. rm. Adopting everything but "make clean" to a stock AmigaDOS/Lattice
  38. environment should be pretty simple. You can compile with both -w &
  39. -rr safely, providing you've got an interface to the
  40. rexxsyslib.library somewhere.
  41.  
  42. The code in filter.c uses an operator precedence parser to deal with
  43. the expressions. It looks like black magic, but works very well,
  44. especially if you're going to interpret it via a stack mechanism.
  45. Since the result (in both cases) doesn't use system stack, I consider
  46. this a major win. The one extra thing I'm thinking about doing is an
  47. "optimization" pass over the finished expression, to take out the
  48. targets of the short-circuit "and"'s & "or"'s (just make everything that
  49. points to <shortcircuitnode> point to <shortcircuitnode>->n_next).
  50.  
  51. If you don't have REXX, or want a version without REXX support,
  52. compile with -dNO_REXX. This will cause unrecognized tokens to
  53. generate parse errors instead of REXX invocations. It also makes the
  54. REXX support code vanish. I thought about using Execute instead of
  55. ARexx, but 1) if you've got both, you can do one from the other
  56. anyway; 2) ARexx feels like the right thing to use in this case; and
  57. 3) Getting the Execute right depends heavily on your environment
  58. (WShell, Shell, csh, CLI, etc.). If you think you can make it work
  59. right in all environments, let me know.
  60.